package edu.scnu.fans.fingertip.user.output;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.Instant;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class UserOutput {

    private Long id;

    private Instant created;
    private Instant updated;

    @ApiModelProperty("用户名")
    private String username;
    @ApiModelProperty("昵称")
    private String nickname;
    @ApiModelProperty("头像图片")
    private String img;
    @ApiModelProperty("手机号")
    private String mobile;
    @ApiModelProperty("性别 1:男; 0:女")
    private Integer gender;

    @ApiModelProperty("登陆接口会返回 token")
    private String token;

    public UserOutput(Long id, Instant created, Instant updated, String username, String nickname, String img, String mobile, Integer gender) {
        this.id = id;
        this.created = created;
        this.updated = updated;
        this.username = username;
        this.nickname = nickname;
        this.img = img;
        this.mobile = mobile;
        this.gender = gender;
    }
}
